#include <extend.h>

extern CLIPVAR  errorBlock;
extern PCLIPVAR _tos, _eval;
extern PDYNSYM _symEval;

void Debug( LPSTR );

//----------------------------------------------------------------------------//

PCLIPVAR _errNew( void )
{
   _PutDynSym( _GetDynSym( "ERRORNEW" ) );
   _PutNil();
   _do( 0 );

   return _eval;
}

//----------------------------------------------------------------------------//

void _errPutDescription( PCLIPVAR pError, LPSTR szDescription )
{
   _PutDynSym( _GetDynSym( "_DESCRIPTION" ) );
   _Push( pError );
   _PutC( szDescription );
   _Send( 1 );
}

//----------------------------------------------------------------------------//

WORD _errLaunch( PCLIPVAR pError )
{
   _PutDynSym( _symEval );
   _Push( &errorBlock );
   _Push( pError );
   _do( 1 );

   return _eval->iValue;
}

//----------------------------------------------------------------------------//
